<?php
/*
===========================================================================

  Copyright (c) 2010-2012 DSPWeb Development Team

  This program is free software: you can redistribute it and/or modify
  it under the terms of the GNU General Public License as published by
  the Free Software Foundation, either version 3 of the License, or
  (at your option) any later version.

  This program is distributed in the hope that it will be useful,
  but WITHOUT ANY WARRANTY; without even the implied warranty of
  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  GNU General Public License for more details.

  You should have received a copy of the GNU General Public License
  along with this program.  If not, see http://www.gnu.org/licenses/

  This file is part of DSPWeb source code

===========================================================================
*/

if (!empty($error)) {
$output .= '
<table cellpadding=0 cellspacing=0 width="45%" border="0" style="border: 1px solid #F00; border-radius: 5px; background-color: #FFA8A8; color: #F00; font-family: Verdana; font-size: 12px;">
  <tr>
    <td style="border-right: 1px solid #F00; padding: 5px; font-weight: bold; font-size: 16px; text-align: center;">!</td>
    <td style="padding: 5px; vertical-align: middle; text-align: center;">'.$error.'</td>
  </tr>
</table></center>';
}
$output .= '
<form method="post" action="login.php">
<br />
<center><table width="50%" border="0" style="border: 1px solid #c0c0c0;" cellpadding=0 cellspacing=0>
  <tr>
    <td style="background-color: #f1f3f5; border-bottom: 1px solid #c0c0c0; padding: 5px; font-weight: bold; font-size: 12px; color: #3f6fbc;">DSPWeb Login</td>
  </tr>
  <tr>
    <td style="padding: 10px;"><center><table border="0" style="border: 1px solid #C0c0c0; background-color: #F1F3F5; padding: 5px;">
      <tr>
        <td style="text-align: right; font-weight: bold; font-size: 12px; vertical-align: middle;">Username:</td>
        <td><input type="text" name="username" style="border: 1px solid #c0c0c0; background-color: #fff; font-family: Verdana; font-size: 12px; padding: 2px;"></td>
      </tr>
      <tr>
        <td style="text-align: right; font-weight: bold; font-size: 12px; vertical-align: middle;">Password:</td>
        <td><input type="password" name="password" style="border: 1px solid #c0c0c0; background-color: #fff; font-family: Verdana; font-size: 12px; padding: 2px;"></td>
      </tr>';
	  if ($enable_registration) {
	  $output .= '
      <tr>
        <td colspan=2 style="text-align: center; font-family: Verdana; font-size: 12px; vertical-align: middle;"><span style="font-size: 10px; text-align: left;">Don\'t have an account? [<a href="register.php" style="font-weight: bold;">Create one</a>]</span></td>
      </tr>';
	  }
	  $output .= '
      <tr>
        <td colspan=2 style="text-align: center;"><input type="hidden" name="login" value="1"><input type="submit" value="Login" style="border: 1px solid #c0c0c0; background-color: #f1f3f5;"></form></td>
        <td>&nbsp;</td>
      </tr>
    </table></center></td>
  </tr>
</table></center>';

?>